package com.lk.springboot.dao;

import com.lk.springboot.pojo.UserToken;
import org.apache.ibatis.annotations.*;

/**
 * @author lk
 * @date 2020/1/9 0009 17:00
 */
@Mapper
public interface UserTokenMapper {
    @Insert("insert into user_token(u_id,token) values(#{u_id},#{token})")
    void insertToken(UserToken userToken);

    @Select("select u_id from user_token where token=#{token}")
    String readToken(String token);

}
